Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify creating a global in Singletons (Autoload) #10416

Merged
merged 2 commits into from
Dec 18, 2024

Conversation

The-oldone
Copy link
Contributor

@The-oldone The-oldone commented Dec 17, 2024

The code written below in the page to be added to scene 1 and 2 didn't say how to define the global variable, and neither did this, so I fixed it

The code below to be added to scene 1 and 2 didn't say how to define the global variable, and neither did this, so I fixed it
@AThousandShips AThousandShips added enhancement area:manual Issues and PRs related to the Manual/Tutorials section of the documentation labels Dec 17, 2024
Copy link
Contributor

@tetrapod00 tetrapod00 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's good once either of my suggestion or ATS's is applied.

Worth noting that "Global" (or whatever the PascalCase version of script filename is) does get autofilled when adding the script as a global. So the current text of the page, while technically incomplete, is a valid set of instructions, and this change is not strictly needed.

tutorials/scripting/singletons_autoload.rst Outdated Show resolved Hide resolved
@tetrapod00 tetrapod00 changed the title Update singletons_autoload.rst Clarify creating a global in Singletons (Autoload Dec 17, 2024
@tetrapod00 tetrapod00 changed the title Clarify creating a global in Singletons (Autoload Clarify creating a global in Singletons (Autoload) Dec 17, 2024
Added tetrapod's suggestion

Co-authored-by: tetrapod <[email protected]>
@The-oldone
Copy link
Contributor Author

@tetrapod00 added them, you could merge it now

and yes, it does come in the autocomplete, but as a beginner would copy paste the code of scene 1 and 2 in the example, they might not understand that they have to do that

@tetrapod00 tetrapod00 merged commit d5b8afb into godotengine:master Dec 18, 2024
1 check passed
@tetrapod00
Copy link
Contributor

Thanks, and congratulations on your first merged contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:manual Issues and PRs related to the Manual/Tutorials section of the documentation cherrypick:4.3 enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants